package com.icedata.sika.core

import com.icedata.sika.bridge.SikaEvent


/**
 * 解析处理器
 * @param function 解析函数的具体实现
 */
class ParseProcessor constructor(priority: Int = 5000, function: suspend (SikaEvent, Sika) -> List<Command>) :
    AbstractAsyncProcessor<SikaEvent, List<Command>>(function, priority) {

    constructor(priority: Int = 5000, function: suspend (SikaEvent) -> List<Command>) : this(
        priority,
        { messageEvent, _ -> function(messageEvent) }
    )

    override fun onMount(sika: Sika) {
//        TODO("Not yet implemented")
    }

    override fun onUnmount(sika: Sika) {
//        TODO("Not yet implemented")
    }

    override var priority: Int = 5000
}